<!DOCTYPE HTML>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <title>个人资料-教育论坛</title>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <link rel="stylesheet" href="/css/bootstrap.min.css">
    <link rel="stylesheet" href="/css/bootstrap-theme.min.css">
    <script src="/js/jquery-3.6.0.min.js"></script>
    <script src="/js/bootstrap.min.js"></script>
</head>
<body style="background-color: #eee">
    <div th:insert="~{navigation :: nav}"></div>
    <div>
        <div class="row">
            <div class="col-md-8 col-md-offset-2" style="background-color: white">
                <div style="margin-top: 50px">
                    <div class="row">
                        <div class="col-xs-6 col-md-3">
                            <div class="col-md-1 col-md-offset-1">
                                <img th:src="${user.avatarUrl}" style="height: 250px;width: 250px;position: relative;left: 142px;top: -19px;">
                            </div>
                        </div>
                        <div class="col-xs-6 col-md-4"></div>
                        <div class="col-xs-6 col-md-4">
                            <div class="list-group">
                                <a th:href="@{'/profile/'+${session.user.id}+'/questions'}" class="list-group-item"><span class="badge" th:text="${user.questionCount}"></span>我的帖子</a>
                                <a th:href="@{'/profile/'+${session.user.id}+'/replies'}" class="list-group-item"><span class="badge" th:text="${user.commentCount}"></span>我的回帖</a>
                            </div>
                        </div>
                    </div>
                    <hr>
                    <h4>昵称&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;贴子数&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;回复数&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;点赞数</h4>
                    <blockquote th:each="question : ${pagination.questions}">
                        <div class="media" >
                            <div class="media-left">
                                <a th:href="@{'/profile/'+${question.user.id}}">
                                    <img class="media-object img-rounded"
                                         style="width: 60px;height: 60px;"
                                         th:src="${question.user.avatarUrl}">
                                </a>
                            </div>
                            <div class="media-body">
                                <h4 class="media-heading" >
                                    <a th:href="@{'/question/'+${question.id}}" th:text="${question.title}"></a>
                                </h4>
                                <span th:text="${question.description}"></span> <br>
                                <span class="text-desc"><span th:text="${question.commentCount}"></span> 个回复 • <span th:text="${question.viewCount}"></span> 次浏览 • <span th:text="${#dates.format(question.gmtCreate,'yyyy-MM-dd HH:mm')}"></span></span>
                            </div>
                        </div>
                    </blockquote>
                </div>
            </div>
        </div>
    </div>
</body>
</html>